<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
    <!--Import Google Icon Font-->
    <link href="http://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
    <!--Import materialize.css-->
    <!--<link type="text/css" rel="stylesheet" href="materialize/css/materialize.min.css"  media="screen,projection"/>-->
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.8/css/materialize.min.css">
    <style type="text/css">
        img{
            position: absolute;
            top: 0px;
            bottom: 0px;
            left: 0px;
            right: 0px;
        }
    </style>
    <title>登录</title>
</head>
<body>
<div id="loginmodal" class="modal">
    <div class="modal-content">
        <h4>呜呼</h4>
        <div class="row">
            <form class="col s12" action="/users/login" method="post">
                <div class="row">
                    <div class="input-field col s12">
                        <i class="material-icons prefix">account_circle</i>
                        <input id="account" name="account" type="text">
                        <label for="account">账号</label>
                    </div>
                    <div class="input-field col s12">
                        <i class="material-icons prefix">keyboard</i>
                        <input id="passwd" name="password" type="password">
                        <label for="passwd">密码</label>
                    </div>
                    <!--<button type="submit" class="waves-effect blue white-text darken-text-2">登录</button>-->
                    <div class="center row">
                        <button class="btn waves-effect blue white-text darken-text-2" type="submit">登录</button>
                    </div>
                    <div class="center">
                        <a style="display: block;" href="/users/toRegister">还没有账号？点击注册吧！</a>
                    </div>
                </div>
            </form>
        </div>
    </div>
    <div class="modal-footer"></div>
</div>

<div class="slider fullscreen">
    <!--<div class="row">-->
    <div class="center">
        <a class="btn waves-effect black grey-text darken-text-2 " href="#loginmodal" style="z-index: 3;">登录呜呼</a>
    </div>
    <!--</div>-->
    <ul class="slides">
        <li>
            <img src="../../img/4.jpg">
        </li>
        <li>
            <img src="../../img/5.jpg">
        </li>
        <li>
            <img src="../../img/6.jpg">
        </li>
    </ul>
</div>
<!--Import jQuery before materialize.js-->
<script type="text/javascript" src="https://code.jquery.com/jquery-2.1.1.min.js"></script>
<!--<script type="text/javascript" src="materialize/js/materialize.min.js"></script>-->
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.97.8/js/materialize.min.js"></script>
<script>
    $(document).ready(function(){
        $('.slider').slider({full_width: true});
        // 模态框
        $('.modal').modal({
            opacity:0,
            dismissible:true
        });
        // 模态框
        $('.modal').modal({
            opacity:0,
            dismissible:true
        });
    });

    $(document).ready(function () {
        $("#register").on("click",function () {
            // alert("我被点击了")
            // $.ajax({
            //     url : '/users/toRegister',
            //     type : "get",
            //     dataType : "json",
            //     success : function(data, textStatus, jqXHR) {
            //         if ('success' == textStatus) {
            //              alert("success");
            //         }
            //     },
            //     error : function(XMLHttpRequest, textStatus, errorThrown) {
            //          alert("error");
            //     }
            // });
        });
    });
</script>
</body>
</html>